diode circuit analysis problems and solutions